package edu.sctu.practice.class02.yangshengyu.assign03.test01;

/**
 * Created by Cullen on 2015/10/22.
 */
public class Rectangle extends GeometricObject {

    public Rectangle(double weight, double height, String name, String color) {
        this.weight = weight;
        this.height = height;
        this.name = name;
        this.color = color;
    }

    public double findArea() {
        return this.weight * this.height;
    }

    public double findPerimeter() {
        return this.weight * 2 + this.height * 2;
    }

}

